Skip to content

gh-123284: fix _pylong decimal context creation#123285

Closed
picnixz wants to merge 2 commits into
python:mainfrom
picnixz:fix-pylong-refleaks
Closed

gh-123284: fix _pylong decimal context creation#123285
picnixz wants to merge 2 commits into
python:mainfrom
picnixz:fix-pylong-refleaks

Conversation

@picnixz

@picnixz picnixz commented Aug 24, 2024

Copy link
Copy Markdown
Member

This also makes _pylong no longer leak references due to the contextvars in decimal, although _pydecimal (and _decimal) will still leak once we call decimal.getcontext().

@picnixz picnixz changed the title gh-123284: fix _pylong decimal context creation (and refleaks) gh-123284: fix _pylong decimal context creation Aug 24, 2024

@vstinner vstinner left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change is maybe hidden the problem, but I don't think that it's a fix: #123284 (comment)

I don't think that _pylong.py code is wrong.

@picnixz picnixz marked this pull request as draft September 5, 2024 23:04
@picnixz

picnixz commented Sep 5, 2024

Copy link
Copy Markdown
Member Author

Converting into draft until I solved the original issue.

@picnixz

picnixz commented Sep 6, 2024

Copy link
Copy Markdown
Member Author

Actually, this will be fixed by #123703 because what's missing the Py_VISIT on the signals and cond maps.

@picnixz picnixz closed this Sep 6, 2024
@picnixz picnixz deleted the fix-pylong-refleaks branch September 6, 2024 11:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants